package com.whw.fy.mapper;

import com.whw.fy.entity.Clazz;
import java.util.List;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

@Mapper
public interface ClazzMapper {
    int deleteByPrimaryKey(Integer classId);

    int insert(Clazz record);

    int insertSelective(Clazz record);

    Clazz selectByPrimaryKey(Integer classId);

    int updateByPrimaryKeySelective(Clazz record);

    int updateByPrimaryKey(Clazz record);

    int updateBatch(List<Clazz> list);

    int updateBatchSelective(List<Clazz> list);

    int batchInsert(@Param("list") List<Clazz> list);

    List<Clazz> selectByClassStatus(@Param("classStatus") Integer classStatus);


    List<Clazz> selectAll();

    List<Clazz> selectByClassTeacherId(@Param("classTeacherId") Integer classTeacherId);

    List<Clazz> selectByClassResponsibleTeacherId(@Param("classResponsibleTeacherId") Integer classResponsibleTeacherId);

    //对学生id进行模糊搜索
    List<Clazz> selectByClassCourseIdAndStudentIdMohu(@Param("classCourseId") Integer classCourseId, @Param("studentId") String studentId);

    //查询老师下面所有未完成的课程
    List<Clazz> selectByClassTeacherIdAndStatus01(@Param("classTeacherId") Integer classTeacherId);

    List<Clazz> selectByStatus01();

    int updateClassCompletionTimesByClassId(@Param("updatedClassCompletionTimes") Integer updatedClassCompletionTimes, @Param("classId") Integer classId);

    List<Clazz> selectByClassCourseIdAndClassStatus(@Param("classCourseId") Integer classCourseId, @Param("classStatus") Integer classStatus);

    List<Clazz> selectByClassMedicalDirectorId(@Param("classMedicalDirectorId") Integer classMedicalDirectorId);

    Clazz selectByClassName(@Param("className")String className);


}